package com.jcfk.eam.domain.dto.base;

import com.jcfk.eam.domain.dto.main.EamRepairOrderPartDTO;
import com.jcfk.eam.domain.dto.main.EamRepairOrderPersonDTO;
import com.jcfk.system.domain.dto.BaseDTO;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * 维修单
 *
 * @author awei
 * @email 522891237@gqq.com
 * @date 2024-08-26
 */
@Data
public class EamRepairOrderDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    /**
     * 数据版本号
     */
    private Long version;

    /**
     * 维修设备id
     */
    @Length(max = 32, message = "维修设备")
    private String assetId;

    /**
     * 任务ID
     */
    private String taskId;

    /**
     * 报修时间
     */
    private Date repairTime;

    /**
     * 报修人
     */
    @Length(max = 32, message = "报修人长度不能超过32")
    private String repairUser;

    private String repairUserName;
    /**
     * 故障状态
     */
    @Length(max = 32, message = "故障状态长度不能超过32")
    private String faultStatus;

    /**
     * 故障等级
     */
    @Length(max = 32, message = "故障等级长度不能超过32")
    private String repairLevel;

    /**
     * 维修班组
     */
    @Length(max = 32, message = "维修班组长度不能超过32")
    private String repairTeamId;
    private String repairTeamCode;
    @Length(max = 32, message = "维修人长度不能超过32")
    private String repairTeamName;

    /**
     * 维修人
     */
    @Length(max = 32, message = "维修人id长度不能超过32")
    private String repairTeamUser;


    /**
     * 维修人用户主键
     */
    private String repairTeamSysUser;

    @Length(max = 32, message = "维修人长度不能超过32")
    private String repairTeamUserName;

    private String repairTeamUserEmpNo;

    /**
     * 故障描述
     */
    @Length(max = 255, message = "故障描述长度不能超过255")
    private String remarks;

    /**
     * 应答时间
     */
    private Date answerTime;

    /**
     * 到达时间
     */
    private Date repairStartTime;

    /**
     * 维修完成时间
     */
    private Date repairEndTime;

    /**
     * 维修用时(小时)
     */
    private BigDecimal repairUseTime;

    /**
     * 故障模式主键
     */
    @Length(max = 32, message = "故障模式长度不能超过32")
    private String faultModeId;

    /**
     * 故障模式
     */
    @Length(max = 32, message = "故障模式长度不能超过32")
    private String faultMode;

    /**
     * 故障现象主键
     */
    @Length(max = 32, message = "故障现象长度不能超过32")
    private String faultPhenomenonId;

    /**
     * 故障现象
     */
    @Length(max = 32, message = "故障现象长度不能超过128")
    private String faultPhenomenon;

    /**
     * 故障原因主键
     */
    @Length(max = 32, message = "故障原因长度不能超过32")
    private String faultReasonId;

    /**
     * 故障原因
     */
    @Length(max = 32, message = "故障原因长度不能超过128")
    private String faultReason;

    /**
     * 故障部位主键
     */
    @Length(max = 32, message = "故障部位长度不能超过32")
    private String faultPositionId;

    /**
     * 故障部位
     */
    @Length(max = 32, message = "故障部位长度不能超过32")
    private String faultPosition;

    /**
     * 处理措施主键
     */
    @Length(max = 32, message = "处理措施长度不能超过32")
    private String faultHandleMeasureId;

    /**
     * 处理措施
     */
    @Length(max = 32, message = "处理措施长度不能超过128")
    private String faultHandleMeasure;

    /**
     * 维修情况
     */
    @Length(max = 32, message = "维修情况长度不能超过32")
    private String repairSituation;

    /**
     * 维修状态
     */
    @Length(max = 32, message = "维修状态长度不能超过32")
    private String repairStatus;

    /**
     * 是否委外
     */
    @Length(max = 32, message = "是否委外长度不能超过32")
    private String outSourcing;

    /**
     * 创建人名
     */
    @Length(max = 50, message = "创建人名长度不能超过50")
    private String createdUserName;

    /**
     * 更新人名
     */
    @Length(max = 50, message = "更新人名长度不能超过50")
    private String lastUpdatedUserName;

    /**
     * 是否停用
     */
    private Integer enabled;

    /**
     * 是否删除
     */
    private Integer deleted;

    /**
     * 资产大类
     */
    private Integer assetKind;

    /**
     * 批量删除id
     */
    private List<String> ids;

    /**
     * 资产编号
     */
    @Length(max = 32, message = "资产编号长度不能超过32")
    private String assetCode;

    /**
     * 资产名称
     */
    @Length(max = 50, message = "资产名称长度不能超过50")
    private String assetName;

    /**
     * 资产管理人主键
     */
    @Length(max = 32, message = "资产管理人主键长度不能超过32")
    private String assetManagerId;

    /**
     * 资产管理人
     */
    @Length(max = 50, message = "资产管理人长度不能超过50")
    private String assetManagerName;

    /**
     * 使用部门主键
     */
    @Length(max = 32, message = "使用部门主键长度不能超过32")
    private String usingDepartmentId;

    @Length(max = 50, message = "使用部门长度不能超过50")
    private String usingDepartmentName;
    private String usingPersonName;

    private List<EamRepairOrderFileDTO> images = new ArrayList<>();


    private String repairSource;
    private String repairCode;
    private String assetTypeId;
    private String assetTypeCode;
    private String assetTypeName;
    private String assetBrandName;
    private String assetModelNo;
    private String locationName;

    private List<EamRepairOrderPartDTO> parts;

    private List<EamRepairOrderFileDTO> executeFiles = new ArrayList<>();

    private String memo;

    /**
     * 参与维修人员
     */
    private List<EamRepairOrderPersonDTO> repairOrderPersons;

    private String pointCheckDetailId;

    /**
     * 备件数量
     */
    private Integer sparePartNumber;
    /**
     * 备件编号
     */
    private String spareCode;
    /**
     * 备件名称
     */
    private String spareNmae;
    /**
     * 备件类型
     */
    private String spareType;
}
